GParamSpec *pspec,
GtkWindow *self)
{
- gtk_window_set_title_internal (self, gtk_header_bar_get_title (titlebar),
- FALSE);
+ const gchar *title;
+
+ title = gtk_header_bar_get_title (titlebar);
+ gtk_window_set_title_internal (self, title, FALSE);
}
/**
priv->title_box = titlebar;
gtk_widget_set_parent (priv->title_box, widget);
- g_signal_connect (titlebar, "notify::title",
- G_CALLBACK (on_titlebar_title_notify), window);
+ if (GTK_IS_HEADER_BAR (titlebar))
+ {
+ g_signal_connect (titlebar, "notify::title",
+ G_CALLBACK (on_titlebar_title_notify), window);
+ on_titlebar_title_notify (GTK_HEADER_BAR (titlebar), NULL, window);
+ }
visual = gdk_screen_get_rgba_visual (gtk_widget_get_screen (widget));
if (visual)